package orchestration.android.demo;

import orchestration.android.R;
import android.app.ListActivity;
import android.database.MatrixCursor;
import android.net.Uri;
import android.os.Bundle;
import android.os.Parcelable;
import android.widget.SimpleCursorAdapter;

public class ShowUriArrayActivity extends ListActivity{

	private static final String[] COLUMNS = new String[]{"_id","title","desc"};
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		Parcelable[] array=getIntent().getParcelableArrayExtra("array");
		
		MatrixCursor c= new MatrixCursor(COLUMNS);
		c.addRow(array);
		startManagingCursor(c);
		SimpleCursorAdapter adapter = new SimpleCursorAdapter(this, R.layout.execution_list_item, c,
				new String[]{"title","desc"}, new int[] { R.id.text_execution_name, R.id.text_execution_status });
		setListAdapter(adapter);
	}
}
